using System;
using L=Science.Physics.GeneralPhysics;

namespace Serway.Chapter14
{
	/// <summary>
	/// Example05: Eureka!
	/// Archimedes supposedly was asked to determine whether 
	/// a crown made for the king consisted of pure gold. 
	/// Legend has it that he solved this problem by weighing 
	/// the crown Figure 14.12. Suppose the scale read 7.84 N 
	/// in air and 6.84N in water. What should Archimedes have 
	/// told the king?
	/// \rho_c = 7.84 \times 10^3 kg/m^3
	/// </summary>
	public class Example05
	{
		public Example05()
		{
		}
		private string result;
		public string Result
		{
			get{return result;}
		}
		public void Compute()
		{
			L.Density water = new L.Density();
			water.kgPERmCUBE = 1000.0;
			L.Volume v = new L.Volume();
			v.mCUBE = 1.0/water.kgPERmCUBE/L.Constant.AccelerationOfGravity;
			L.Density gold = new L.Density();
			gold.kgPERmCUBE = 7.84/v.mCUBE/L.Constant.AccelerationOfGravity;
			result += Convert.ToString(gold.kgPERmCUBE);
		}
	}
}
